package com.pi.shisan.diy.config;

import javafx.application.Platform;
import org.springframework.beans.factory.DisposableBean;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Component;

@Primary
@Component
public class DestroyListenerAsFx implements DisposableBean{

    @Override
    public void destroy() throws Exception {
        Platform.exit();
    }
}
